package pojo;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Component;


//组件等价于<bean id="door" class="pojo.House"/>
@Component
public class House {
    public String room;
    public String door = "金拱门";


    @Value("彩虹窗")//显示地加入一个值 相当于<property name="window" value="彩虹窗户"/>
    public  String window ;
    @Value("总统套房")
    public void setRoom(String room){
        this.room = room;
    }


}
